package com.jtny.nytb.datafilling.service;

import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import com.jtny.nytb.datafilling.dto.InstitutionEquipmentDTO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@Api(value = "制度设备关联接口", tags = "制度设备关联service接口")
public interface InstitutionEquipmentService{

    @ApiOperation("根据设备id查制度设备关联信息")
    @ApiImplicitParam(name = "equipmentId", value = "设备id", required = true, paramType = "query")
    @ApiOperationSupport(order = 1)
    @GetMapping("/getByEquipmentId/{equipmentId}")
    @ResponseBody
    InstitutionEquipmentDTO getByEquipmentId(@PathVariable("equipmentId") Long equipmentId);

    @ApiOperation("根据设备id批量查制度设备关联信息")
    @ApiImplicitParam(name = "equipmentIds", value = "设备id", required = true, paramType = "query")
    @ApiOperationSupport(order = 2)
    @PostMapping("/getByEquipmentIds")
    @ResponseBody
    List<InstitutionEquipmentDTO> getByEquipmentIds(@RequestBody List<Long> equipmentIds);

}